import Dicom.DcmRcv;

import java.io.IOException;

public class MainServer {
    public static void main(String[] args) {
        DcmRcv dcmrcv = new DcmRcv(MainConfig.AeTitle);
        dcmrcv.setPort(MainConfig.Port);
        dcmrcv.setAEtitle(MainConfig.AeTitle);
        dcmrcv.setHostname(MainConfig.Host);
        dcmrcv.setDestination(MainConfig.saveFile);
        dcmrcv.setStgCmtReuseFrom(false);
        dcmrcv.setStgCmtReuseTo(false);
        dcmrcv.setPackPDV(true);
        dcmrcv.setTcpNoDelay(true);
        dcmrcv.initTransferCapability();
        try {
            dcmrcv.start();
        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}
